package com.ys.lambda;

/**
 * <p>@description:</p>
 *
 * @author yangshuang
 * @version v1.0
 * @date 2018/2/6 13:57
 */
public class YsSelectorTest {

    public static void main(String[] args) {

        modifyValue(10, x -> {
            if (x > 5) {
                return 3;
            }
            return 2;
        });
    }

    private static void modifyValue(int value, YsSelector<Integer> ysSelector) {


        Integer newValue = ysSelector.execute(value);

        System.out.println(newValue);
    }

}
